
package com.yanboo.logging.domain;

import com.yanboo.common.base.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import jakarta.persistence.*;
import jakarta.validation.constraints.NotBlank;
import java.io.Serializable;

/**
 * 七牛云对象存储配置类
 */
@Data
@Entity
@Table(name = "tool_qiniu_config")
public class QiniuConfig extends BaseEntity implements Serializable {


    @NotBlank
    @Schema(description = "accessKey")
    @Lob
    private String accessKey;

    @NotBlank
    @Schema(description = "secretKey")
    @Lob
    private String secretKey;

    @NotBlank
    @Schema(description = "存储空间名称作为唯一的 Bucket 识别符")
    private String bucket;

    /**
     * Zone表示与机房的对应关系
     * 华东	Zone.zone0()
     * 华北	Zone.zone1()
     * 华南	Zone.zone2()
     * 北美	Zone.zoneNa0()
     * 东南亚	Zone.zoneAs0()
     */
    @NotBlank
    @Schema(description = "Zone表示与机房的对应关系")
    private String zone;

    @NotBlank
    @Schema(description = "外链域名，可自定义，需在七牛云绑定")
    private String host;

    @Schema(description = "空间类型：公开/私有")
    private String type = "公开";
}
